///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Sep  8 2010)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////

#include "cardworddialog.h"

///////////////////////////////////////////////////////////////////////////

CardWordDialog::CardWordDialog( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style )
{
	this->SetSizeHints( wxSize( 700,300 ), wxSize( 700,-1 ) );
	
	wxBoxSizer* mainSizer;
	mainSizer = new wxBoxSizer( wxVERTICAL );
	
	m_listCtrl = new wxListCtrl( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLC_HRULES|wxLC_REPORT|wxLC_VRULES );
	mainSizer->Add( m_listCtrl, 1, wxALL|wxEXPAND, 5 );
	
	m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
	mainSizer->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 );
	
	wxBoxSizer* buttonSizer;
	buttonSizer = new wxBoxSizer( wxHORIZONTAL );
	
	m_staticTextScore = new wxStaticText( this, wxID_ANY, _("Score:"), wxDefaultPosition, wxDefaultSize, 0 );
	m_staticTextScore->Wrap( -1 );
	buttonSizer->Add( m_staticTextScore, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
	
	m_textCtrlScore = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
	buttonSizer->Add( m_textCtrlScore, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
	
	m_buttonOk = new wxButton( this, wxID_OK, _("&Ok"), wxDefaultPosition, wxDefaultSize, 0 );
	m_buttonOk->SetDefault(); 
	buttonSizer->Add( m_buttonOk, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
	
	m_buttonCancel = new wxButton( this, wxID_CANCEL, _("&Cancel"), wxDefaultPosition, wxDefaultSize, 0 );
	buttonSizer->Add( m_buttonCancel, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
	
	m_buttonDelete = new wxButton( this, wxID_ANY, _("Delete"), wxDefaultPosition, wxDefaultSize, 0 );
	m_buttonDelete->Enable( false );
	
	buttonSizer->Add( m_buttonDelete, 0, wxALL, 5 );
	
	m_buttonAdd = new wxButton( this, wxID_ANY, _("Add"), wxDefaultPosition, wxDefaultSize, 0 );
	buttonSizer->Add( m_buttonAdd, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
	
	m_buttonPlay = new wxButton( this, wxID_ANY, _("Play"), wxDefaultPosition, wxDefaultSize, 0 );
	m_buttonPlay->Enable( false );
	
	buttonSizer->Add( m_buttonPlay, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
	
	mainSizer->Add( buttonSizer, 0, wxALIGN_CENTER_HORIZONTAL, 5 );
	
	this->SetSizer( mainSizer );
	this->Layout();
	
	this->Centre( wxBOTH );
	
	// Connect Events
	this->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ) );
	m_listCtrl->Connect( wxEVT_ENTER_WINDOW, wxMouseEventHandler( CardWordDialog::OnEnterWindow ), NULL, this );
	m_listCtrl->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_listCtrl->Connect( wxEVT_LEFT_DCLICK, wxMouseEventHandler( CardWordDialog::OnLeftDClick ), NULL, this );
	m_listCtrl->Connect( wxEVT_COMMAND_LIST_DELETE_ITEM, wxListEventHandler( CardWordDialog::OnWordDeselected ), NULL, this );
	m_listCtrl->Connect( wxEVT_COMMAND_LIST_ITEM_DESELECTED, wxListEventHandler( CardWordDialog::OnWordDeselected ), NULL, this );
	m_listCtrl->Connect( wxEVT_COMMAND_LIST_ITEM_SELECTED, wxListEventHandler( CardWordDialog::OnWordSelected ), NULL, this );
	m_textCtrlScore->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonOk->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnOkClick ), NULL, this );
	m_buttonOk->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnCancelClick ), NULL, this );
	m_buttonCancel->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonDelete->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnDeleteClick ), NULL, this );
	m_buttonDelete->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonAdd->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnAddClick ), NULL, this );
	m_buttonAdd->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonPlay->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnPlayClick ), NULL, this );
	m_buttonPlay->Connect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
}

CardWordDialog::~CardWordDialog()
{
	// Disconnect Events
	this->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ) );
	m_listCtrl->Disconnect( wxEVT_ENTER_WINDOW, wxMouseEventHandler( CardWordDialog::OnEnterWindow ), NULL, this );
	m_listCtrl->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_listCtrl->Disconnect( wxEVT_LEFT_DCLICK, wxMouseEventHandler( CardWordDialog::OnLeftDClick ), NULL, this );
	m_listCtrl->Disconnect( wxEVT_COMMAND_LIST_DELETE_ITEM, wxListEventHandler( CardWordDialog::OnWordDeselected ), NULL, this );
	m_listCtrl->Disconnect( wxEVT_COMMAND_LIST_ITEM_DESELECTED, wxListEventHandler( CardWordDialog::OnWordDeselected ), NULL, this );
	m_listCtrl->Disconnect( wxEVT_COMMAND_LIST_ITEM_SELECTED, wxListEventHandler( CardWordDialog::OnWordSelected ), NULL, this );
	m_textCtrlScore->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonOk->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnOkClick ), NULL, this );
	m_buttonOk->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnCancelClick ), NULL, this );
	m_buttonCancel->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonDelete->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnDeleteClick ), NULL, this );
	m_buttonDelete->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonAdd->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnAddClick ), NULL, this );
	m_buttonAdd->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	m_buttonPlay->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CardWordDialog::OnPlayClick ), NULL, this );
	m_buttonPlay->Disconnect( wxEVT_KEY_DOWN, wxKeyEventHandler( CardWordDialog::OnKeyDown ), NULL, this );
	
}
